package ${sysTableVo.packageName}.entity.dto.edit;

import ${sysTableVo.packageName}.entity.bo.${sysTableVo.bigClassName}Bo;
import ${sysTableVo.packageName}.entity.po.${sysTableVo.bigClassName};
import io.github.linpeilie.annotations.AutoMapper;
import io.github.linpeilie.annotations.AutoMappers;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotBlank;
import java.io.Serializable;

#foreach ($import in $importList)
import ${import};
    #if($foreach.count == $importList.size())

    #end
#end
/**
 * Edit${sysTableVo.bigClassName}:
 *
 * @author ${sysTableVo.functionAuthor}
 * @create ${datetime}
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Accessors(chain = true)
@Schema(description = "${sysTableVo.comment}")
@AutoMappers({
    @AutoMapper(target = ${sysTableVo.bigClassName}.class, reverseConvertGenerate = false),
    @AutoMapper(target = ${sysTableVo.bigClassName}Bo.class, reverseConvertGenerate = false)
})
public class Edit${sysTableVo.bigClassName} implements Serializable {

    private static final long serialVersionUID = 1L;

#foreach ($sysColumnVo in $sysColumnVoList)
    #if($sysColumnVo.isEdit)
        #set($parentheseIndex=$sysColumnVo.comment.indexOf("（"))
        #if($parentheseIndex != -1)
            #set($comment=$sysColumnVo.comment.substring(0, $parentheseIndex))
        #else
            #set($comment=$sysColumnVo.comment)
        #end
        #if(!$sysColumnVo.isSuperColumn($sysColumnVo.javaField) && $sysColumnVo.name != "deleted" && $sysColumnVo.name != "tenantId")
    /**
      * ${comment}
      */
    @Schema(description = "${comment}")
            #if($sysColumnVo.isRequired)
    @NotBlank(message = "${comment}为必填字段")
            #end
            #if($sysColumnVo.javaType == 'Date')
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
            #end
    private $sysColumnVo.javaType $sysColumnVo.javaField;

        #end
    #end
#end
}
